home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
SGI Hot Mix 14
/
Hot Mix 14.iso
/
HTML
/
vendors
/
finesse
/
examples
/
csh
/
file_selection
< prev
next >
Wrap
Text File
|
1996-06-27
|
807b
|
51 lines
#! /bin/csh
# FINESSEAPPLICATIONKEY spOsFfb||~Lc[
if ( ! $?FINESSEPATH ) \
set FINESSEPATH = /usr/local/finesse
source $FINESSEPATH/fscshinit
set tmpfile = /tmp/$$.tmp
Fsopen
cat << EOT > $tmpfile
FsWindow -title 'Example File Selection'
-btype oxxa ;
FsSeparator;
FsSelectionText -var filename
-label 'Select file:';
FsSeparator;
EOT
Fsdisplay -f $tmpfile
if ("$fsbutton" != "o") then
Fsclose
/bin/rm -f $tmpfile
exit 1
endif
Fssave
if ( $filename != "" ) then
if ( -f $filename ) then
set longlist = `ls -l $filename`
Fsecho -r 3 -c 80 -t "Long listing of $filename"\:
Fsecho \ \ $longlist
else
Fsecho File not found.
endif
else
Fsecho No file selected.
endif
cat << EOT > $tmpfile
FsWindow -btype o;
FsSeparator;
EOT
Fsdisplay -m "OK to quit." < $tmpfile
/bin/rm -f $tmpfile
Fsclose